using System;
using System.BusinessObjects.Data;
using System.Data;

namespace Blazing.BusinessObjects.Tagging
{
    public class StatisticTaxonomyTag : DataObject<StatisticTaxonomyTag>
    {
        #region Properties
        public virtual int ID
        {
            get 
            { return GetValue<int>("ID"); }
            set
            {
                BeginEdit();
                SetValue("ID", value);
            }
        }

        public virtual int Hits
        {
            get
            {
                if (GetValue<int>("Hits") == null)
                    return 0;
                else
                    return GetValue<int>("Hits");
            }
            set
            {
                BeginEdit();
                SetValue("Hits", value);
            }
        }

        public virtual int Total
        {
            get 
            {
                if (GetValue<int>("Total") == null)
                    return 0;
                else
                    return GetValue<int>("Total"); 
            }
            set
            {
                BeginEdit();
                SetValue("Total", value);
            }
        }


        public virtual int Searches
        {
            get
            {
                if (GetValue<int>("Searches") == null)
                    return 0;
                else
                    return GetValue<int>("Searches");
            }
            set
            {
                BeginEdit();
                SetValue("Searches", value);
            }
        }       

        public virtual DateTime RowStamp
        {
            get { return GetValue<DateTime>("RowStamp"); }
            set
            {
                SetValue("RowStamp", value);
            }
        }

        TaxonomyTag _taxonomyTag;
        public virtual TaxonomyTag TaxonomyTag
        {
            get
            {
                return _taxonomyTag;
            }
            set
            {
                BeginEdit();
                _taxonomyTag = value;
            }
        }
      
        #endregion  
    }
}
